//area section  
          		
function calcLength(){
	
	newt1 = parseFloat(document.frm1.areat1.value);

	 // convert to mm
	if(document.frm1.arealist1.selectedIndex == 1) {newt1 *= 4046900000;}
	if(document.frm1.arealist1.selectedIndex == 2) {newt1 *= 100;}		
	if(document.frm1.arealist1.selectedIndex == 3) {newt1 *= 92900;}
	if(document.frm1.arealist1.selectedIndex == 4) {newt1 *= 10000000000;}
	if(document.frm1.arealist1.selectedIndex == 5) {newt1 *= 645.16;}
	if(document.frm1.arealist1.selectedIndex == 6) {newt1 *= 1000000000000;}
	if(document.frm1.arealist1.selectedIndex == 7) {newt1 *= 1000000;}
	if(document.frm1.arealist1.selectedIndex == 8) {newt1 *= 2590000000000;}
	if(document.frm1.arealist1.selectedIndex == 9) {newt1 *= 1;}
	if(document.frm1.arealist1.selectedIndex == 10){newt1 *= 836100;}
		
		
	 // convert to user's choice
	if(document.frm1.arealist2.selectedIndex == 1) {newt1 /= 4046900000;}
	if(document.frm1.arealist2.selectedIndex == 2) {newt1 /= 100;}
	if(document.frm1.arealist2.selectedIndex == 3) {newt1 /= 92900;}
	if(document.frm1.arealist2.selectedIndex == 4) {newt1 /= 10000000000;}
	if(document.frm1.arealist2.selectedIndex == 5) {newt1 /= 645.16;}
	if(document.frm1.arealist2.selectedIndex == 6) {newt1 /= 1000000000000;}
	if(document.frm1.arealist2.selectedIndex == 7) {newt1 /= 1000000;}
	if(document.frm1.arealist2.selectedIndex == 8) {newt1 /= 2590000000000;}
	if(document.frm1.arealist2.selectedIndex == 9) {newt1 /= 1;}
	if(document.frm1.arealist2.selectedIndex == 10){newt1 /= 836100;}


	//fnewt1 = reducedec(newt1);
	document.frm1.result.value = newt1;
}	
function reducedec(newt1){

strn = newt1.toString();
if(strn.indexOf(".") != -1)
{ io = strn.indexOf(".");
  strn4 = strn.substring(io, (io+5));
  ent = strn.substring(0,io);
  fnewt1 = ent+strn4;
  if(fnewt1.indexOf(".") == 0)fnewt1 = "0"+fnewt1;
}
else {fnewt1 = newt1;}
 return fnewt1;
}


function checkt1(){
	
	if(isNaN(document.frm1.areat1.value)){
			document.frm1.areat1.value = ""
			document.frm1.areat1.focus();  
	}
}